#!/usr/bin/env python
# -*- coding: UTF-8 -*-
'''
@Project ：图灵学习 
@File    ：7.列表嵌套作业.py
@IDE     ：PyCharm 
@Author  ：ChenLiGao
@Date    ：2024-09-26 15:06
'''
import random

'''
    需求： 定义一个学校，学校有三间办公室，完成将八名老师随机分配到三间办公室
'''
teacher_names = ["A", "B", "C", "D", "E", "F", "G", "H"]

offices = [[], [], []]

for name in teacher_names:
    random_num = random.randint(0, 2)
    offices[random_num].append(name)

print(offices)

